Interface sjl.Iterator
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface sjl.Iterator

public interface Iterator
extends Object
The mininum interface that all iterators have in common. It servers as a generic type place holder while the iterator is being passed around.

Copyright © 1996 Finn Bock

See Also:
InputIterator, OutputIterator, ForwardIterator, BidirectionalIterator, RandomIterator, Iter

Method Index

 o cmp(Iterator)
Compare self with another Iterator.
 o genericCopy()
Return a copy of myself.
 o next()
Advance self to the next element in the container.

Methods

 o next
  public abstract Iterator next()
Advance self to the next element in the container.
Returns:
self
 o cmp
  public abstract boolean cmp(Iterator i)
Compare self with another Iterator. This method is implemented in the concrete iterator classes.
Parameters:
i - the iterator to compare with.
Returns:
true if the two iterators are equal (points to the same place).
 o genericCopy
  public abstract Iterator genericCopy()
Return a copy of myself. This copy can then be manipulated.
Returns:
a copy of myself

All Packages  Class Hierarchy  This Package  Previous  Next  Index